<html>
	<head>
		<script type="text/javascript">
			//var wkt = "POINT (-74.8029999999999973 40.3542800000000028)";
			var wkt = "POLYGON (-74.8029999999999973 40.3542800000000028)";
			if (wkt.substr(0, 5) == 'POINT') {
				var wktnums = wkt.substring(wkt.indexOf("(") + 1, wkt.indexOf(")"));
				var coords = wktnums.split(" ");
				console.debug(wktnums);
				console.debug(coords[1]);
				console.debug(coords[0]);
			}
			else {
				console.debug("blah");
			}
		</script>
	</head>
	<body>
		
	</body>
</html>